home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
Cream of the Crop 26
/
Cream of the Crop 26.iso
/
program
/
ddj0897.zip
/
DYN401.ZIP
/
examples
/
exam03
/
main.c
< prev
next >
Wrap
C/C++ Source or Header
|
1995-09-27
|
2KB
|
106 lines
/*
*
* This source code is CONFIDENTIAL and
* PROPRIETARY to Algorithms Corporation. Unauthorized
* distribution, adaptation or use may
* be subject to civil and criminal penalties.
*
* Copyright (c) 1993 Algorithms Corporation
* 3020 Liberty Hills Drive
* Franklin, TN 37064
*
* ALL RIGHTS RESERVED.
*
*
*
*/
#include "generics.h"
main(int argc, char *argv[])
{
object myObj;
InitDynace(&argc);
/* Create and use an instance of the ShortInteger class */
myObj = gNewWithInt(ShortInteger, 6);
gPrint(myObj, stdoutStream);
gChangeShortValue(myObj, 77);
gPrint(myObj, stdoutStream);
gDispose(myObj);
/* Create and use an instance of the String class */
myObj = gNewWithStr(String, "Hello World.");
gPrint(myObj, stdoutStream);
gChangeStrValue(myObj, "New String Value");
gPrint(myObj, stdoutStream);
gDispose(myObj);
/* Create and use an instance of the DoubleFloat class */
myObj = gNewWithDouble(DoubleFloat, 3.1415926);
gPrint(myObj, stdoutStream);
gChangeDoubleValue(myObj, 7.2144);
gPrint(myObj, stdoutStream);
gDispose(myObj);
/* Create and use an instance of the Character class */
myObj = gNewWithChar(Character, 'A');
gPrint(myObj, stdoutStream);
gChangeCharValue(myObj, 'B');
gPrint(myObj, stdoutStream);
gDispose(myObj);
/* Create and use an instance of the Date class */
myObj = gNewWithLong(Date, 19930802L);
gPrint(myObj, stdoutStream);
gChangeLongValue(myObj, 19580608L);
gPrint(myObj, stdoutStream);
gDispose(myObj);
return 0;
}
/*
*
* This source code is CONFIDENTIAL and
* PROPRIETARY to Algorithms Corporation. Unauthorized
* distribution, adaptation or use may
* be subject to civil and criminal penalties.
*
* Copyright (c) 1993 Algorithms Corporation
* 3020 Liberty Hills Drive
* Franklin, TN 37064
*
* ALL RIGHTS RESERVED.
*
*
*
*/